Skip to content

fix(asciidoc): fix empty cell handling#3664

Open
ceberam wants to merge 3 commits into
mainfrom
fix/asciidoc-empty-cells
Open

fix(asciidoc): fix empty cell handling#3664
ceberam wants to merge 3 commits into
mainfrom
fix/asciidoc-empty-cells

Conversation

@ceberam

@ceberam ceberam commented Jun 19, 2026

Copy link
Copy Markdown
Member

Summary

Successfully implemented and tested the fix for empty table cells in AsciiDoc backend, improved the test infrastructure, and renamed test files to follow project conventions.

Resolves #3663

Changes Completed

1. Empty Cell Fix (docling/backend/asciidoc_backend.py)

  • Changed _parse_table_line() to preserve empty cells
  • Empty cells now correctly become empty strings instead of being filtered out
  • Maintains compatibility with format specifier handling

2. Test Infrastructure Improvements (tests/test_backend_asciidoc.py)

  • Removed verbose print statements
  • Added proper GEN_TEST_DATA flag support
  • Uses verify_export() utility like other backends
  • Follows established testing patterns

3. Comprehensive Test Cases (tests/data/asciidoc/asciidoc_02.asciidoc)

  • Added Table 5 with multiple empty cell scenarios
  • Tests empty cells in middle, at end, consecutive empties, and mixed patterns

4. File Renaming (Following Project Convention)

  • Renamed test_*.asciidocasciidoc_*.asciidoc
  • Updated all corresponding groundtruth files
  • All tests pass with new naming

ceberam added 2 commits June 19, 2026 15:03
Signed-off-by: Cesar Berrospi Ramis <ceb@zurich.ibm.com>
Signed-off-by: Cesar Berrospi Ramis <ceb@zurich.ibm.com>
@github-actions

github-actions Bot commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

DCO Check Passed

Thanks @ceberam, all your commits are properly signed off. 🎉

@mergify

mergify Bot commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

Merge Protections

Your pull request matches the following merge protections and will not be merged until they are valid.

🔴 Require two reviewer for test updates

Waiting for

  • #approved-reviews-by >= 2
This rule is failing.

When test data is updated, we require two reviewers

  • #approved-reviews-by >= 2

🟢 Enforce conventional commit

Wonderful, this rule succeeded.

Make sure that we follow https://www.conventionalcommits.org/en/v1.0.0/

  • title ~= ^(fix|feat|docs|style|refactor|perf|test|build|ci|chore|revert)(?:\(.+\))?(!)?:

@codecov

codecov Bot commented Jun 19, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@ceberam

ceberam commented Jun 19, 2026

Copy link
Copy Markdown
Member Author

@ggozad I have spotted this issue while reviewing your last PR #3647 (the issue was already there before your changes)
It would be great if you could have a look at this one.

@ceberam ceberam requested review from cau-git and dolfim-ibm June 19, 2026 13:25
@ceberam ceberam added asciidoc issue related to asciidoc backend bug Something isn't working labels Jun 19, 2026
cau-git
cau-git previously approved these changes Jun 19, 2026
Signed-off-by: Cesar Berrospi Ramis <ceb@zurich.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

asciidoc issue related to asciidoc backend bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Empty table cells in AsciiDoc files are filtered out

2 participants